\(\int \cos ^5(c+d x) \sin (c+d x) (a+b \sin (c+d x)) \, dx\) [1202]

   Optimal result
   Rubi [A] (verified)
   Mathematica [A] (verified)
   Maple [A] (verified)
   Fricas [A] (verification not implemented)
   Sympy [A] (verification not implemented)
   Maxima [A] (verification not implemented)
   Giac [A] (verification not implemented)
   Mupad [B] (verification not implemented)

Optimal result

Integrand size = 25, antiderivative size = 65 \[ \int \cos ^5(c+d x) \sin (c+d x) (a+b \sin (c+d x)) \, dx=-\frac {a \cos ^6(c+d x)}{6 d}+\frac {b \sin ^3(c+d x)}{3 d}-\frac {2 b \sin ^5(c+d x)}{5 d}+\frac {b \sin ^7(c+d x)}{7 d} \]

[Out]

-1/6*a*cos(d*x+c)^6/d+1/3*b*sin(d*x+c)^3/d-2/5*b*sin(d*x+c)^5/d+1/7*b*sin(d*x+c)^7/d

Rubi [A] (verified)

Time = 0.07 (sec) , antiderivative size = 65, normalized size of antiderivative = 1.00, number of steps used = 6, number of rules used = 5, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.200, Rules used = {2913, 2645, 30, 2644, 276} \[ \int \cos ^5(c+d x) \sin (c+d x) (a+b \sin (c+d x)) \, dx=-\frac {a \cos ^6(c+d x)}{6 d}+\frac {b \sin ^7(c+d x)}{7 d}-\frac {2 b \sin ^5(c+d x)}{5 d}+\frac {b \sin ^3(c+d x)}{3 d} \]

[In]

Int[Cos[c + d*x]^5*Sin[c + d*x]*(a + b*Sin[c + d*x]),x]

[Out]

-1/6*(a*Cos[c + d*x]^6)/d + (b*Sin[c + d*x]^3)/(3*d) - (2*b*Sin[c + d*x]^5)/(5*d) + (b*Sin[c + d*x]^7)/(7*d)

Rule 30

Int[(x_)^(m_.), x_Symbol] :> Simp[x^(m + 1)/(m + 1), x] /; FreeQ[m, x] && NeQ[m, -1]

Rule 276

Int[((c_.)*(x_))^(m_.)*((a_) + (b_.)*(x_)^(n_))^(p_.), x_Symbol] :> Int[ExpandIntegrand[(c*x)^m*(a + b*x^n)^p,
 x], x] /; FreeQ[{a, b, c, m, n}, x] && IGtQ[p, 0]

Rule 2644

Int[cos[(e_.) + (f_.)*(x_)]^(n_.)*((a_.)*sin[(e_.) + (f_.)*(x_)])^(m_.), x_Symbol] :> Dist[1/(a*f), Subst[Int[
x^m*(1 - x^2/a^2)^((n - 1)/2), x], x, a*Sin[e + f*x]], x] /; FreeQ[{a, e, f, m}, x] && IntegerQ[(n - 1)/2] &&
 !(IntegerQ[(m - 1)/2] && LtQ[0, m, n])

Rule 2645

Int[(cos[(e_.) + (f_.)*(x_)]*(a_.))^(m_.)*sin[(e_.) + (f_.)*(x_)]^(n_.), x_Symbol] :> Dist[-(a*f)^(-1), Subst[
Int[x^m*(1 - x^2/a^2)^((n - 1)/2), x], x, a*Cos[e + f*x]], x] /; FreeQ[{a, e, f, m}, x] && IntegerQ[(n - 1)/2]
 &&  !(IntegerQ[(m - 1)/2] && GtQ[m, 0] && LeQ[m, n])

Rule 2913

Int[cos[(e_.) + (f_.)*(x_)]^(p_)*((d_.)*sin[(e_.) + (f_.)*(x_)])^(n_.)*((a_) + (b_.)*sin[(e_.) + (f_.)*(x_)]),
 x_Symbol] :> Dist[a, Int[Cos[e + f*x]^p*(d*Sin[e + f*x])^n, x], x] + Dist[b/d, Int[Cos[e + f*x]^p*(d*Sin[e +
f*x])^(n + 1), x], x] /; FreeQ[{a, b, d, e, f, n, p}, x] && IntegerQ[(p - 1)/2] && IntegerQ[n] && ((LtQ[p, 0]
&& NeQ[a^2 - b^2, 0]) || LtQ[0, n, p - 1] || LtQ[p + 1, -n, 2*p + 1])

Rubi steps \begin{align*} \text {integral}& = a \int \cos ^5(c+d x) \sin (c+d x) \, dx+b \int \cos ^5(c+d x) \sin ^2(c+d x) \, dx \\ & = -\frac {a \text {Subst}\left (\int x^5 \, dx,x,\cos (c+d x)\right )}{d}+\frac {b \text {Subst}\left (\int x^2 \left (1-x^2\right )^2 \, dx,x,\sin (c+d x)\right )}{d} \\ & = -\frac {a \cos ^6(c+d x)}{6 d}+\frac {b \text {Subst}\left (\int \left (x^2-2 x^4+x^6\right ) \, dx,x,\sin (c+d x)\right )}{d} \\ & = -\frac {a \cos ^6(c+d x)}{6 d}+\frac {b \sin ^3(c+d x)}{3 d}-\frac {2 b \sin ^5(c+d x)}{5 d}+\frac {b \sin ^7(c+d x)}{7 d} \\ \end{align*}

Mathematica [A] (verified)

Time = 0.14 (sec) , antiderivative size = 86, normalized size of antiderivative = 1.32 \[ \int \cos ^5(c+d x) \sin (c+d x) (a+b \sin (c+d x)) \, dx=-\frac {350 a+525 a \cos (2 (c+d x))+210 a \cos (4 (c+d x))+35 a \cos (6 (c+d x))-525 b \sin (c+d x)+35 b \sin (3 (c+d x))+63 b \sin (5 (c+d x))+15 b \sin (7 (c+d x))}{6720 d} \]

[In]

Integrate[Cos[c + d*x]^5*Sin[c + d*x]*(a + b*Sin[c + d*x]),x]

[Out]

-1/6720*(350*a + 525*a*Cos[2*(c + d*x)] + 210*a*Cos[4*(c + d*x)] + 35*a*Cos[6*(c + d*x)] - 525*b*Sin[c + d*x]
+ 35*b*Sin[3*(c + d*x)] + 63*b*Sin[5*(c + d*x)] + 15*b*Sin[7*(c + d*x)])/d

Maple [A] (verified)

Time = 0.40 (sec) , antiderivative size = 72, normalized size of antiderivative = 1.11

method result size
derivativedivides \(\frac {\frac {b \left (\sin ^{7}\left (d x +c \right )\right )}{7}+\frac {a \left (\sin ^{6}\left (d x +c \right )\right )}{6}-\frac {2 \left (\sin ^{5}\left (d x +c \right )\right ) b}{5}-\frac {\left (\sin ^{4}\left (d x +c \right )\right ) a}{2}+\frac {\left (\sin ^{3}\left (d x +c \right )\right ) b}{3}+\frac {a \left (\sin ^{2}\left (d x +c \right )\right )}{2}}{d}\) \(72\)
default \(\frac {\frac {b \left (\sin ^{7}\left (d x +c \right )\right )}{7}+\frac {a \left (\sin ^{6}\left (d x +c \right )\right )}{6}-\frac {2 \left (\sin ^{5}\left (d x +c \right )\right ) b}{5}-\frac {\left (\sin ^{4}\left (d x +c \right )\right ) a}{2}+\frac {\left (\sin ^{3}\left (d x +c \right )\right ) b}{3}+\frac {a \left (\sin ^{2}\left (d x +c \right )\right )}{2}}{d}\) \(72\)
parallelrisch \(\frac {-210 \cos \left (4 d x +4 c \right ) a -525 a \cos \left (2 d x +2 c \right )+525 b \sin \left (d x +c \right )-15 b \sin \left (7 d x +7 c \right )-35 a \cos \left (6 d x +6 c \right )-63 b \sin \left (5 d x +5 c \right )-35 b \sin \left (3 d x +3 c \right )+770 a}{6720 d}\) \(91\)
risch \(\frac {5 b \sin \left (d x +c \right )}{64 d}-\frac {b \sin \left (7 d x +7 c \right )}{448 d}-\frac {a \cos \left (6 d x +6 c \right )}{192 d}-\frac {3 b \sin \left (5 d x +5 c \right )}{320 d}-\frac {a \cos \left (4 d x +4 c \right )}{32 d}-\frac {b \sin \left (3 d x +3 c \right )}{192 d}-\frac {5 a \cos \left (2 d x +2 c \right )}{64 d}\) \(104\)
norman \(\frac {\frac {2 a \left (\tan ^{2}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{d}+\frac {2 a \left (\tan ^{12}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{d}+\frac {2 a \left (\tan ^{4}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{d}+\frac {2 a \left (\tan ^{10}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{d}+\frac {8 b \left (\tan ^{3}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{3 d}-\frac {32 b \left (\tan ^{5}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{15 d}+\frac {304 b \left (\tan ^{7}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{35 d}-\frac {32 b \left (\tan ^{9}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{15 d}+\frac {8 b \left (\tan ^{11}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{3 d}+\frac {20 a \left (\tan ^{6}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{3 d}+\frac {20 a \left (\tan ^{8}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )}{3 d}}{\left (1+\tan ^{2}\left (\frac {d x}{2}+\frac {c}{2}\right )\right )^{7}}\) \(205\)

[In]

int(cos(d*x+c)^5*sin(d*x+c)*(a+b*sin(d*x+c)),x,method=_RETURNVERBOSE)

[Out]

1/d*(1/7*b*sin(d*x+c)^7+1/6*a*sin(d*x+c)^6-2/5*sin(d*x+c)^5*b-1/2*sin(d*x+c)^4*a+1/3*sin(d*x+c)^3*b+1/2*a*sin(
d*x+c)^2)

Fricas [A] (verification not implemented)

none

Time = 0.37 (sec) , antiderivative size = 62, normalized size of antiderivative = 0.95 \[ \int \cos ^5(c+d x) \sin (c+d x) (a+b \sin (c+d x)) \, dx=-\frac {35 \, a \cos \left (d x + c\right )^{6} + 2 \, {\left (15 \, b \cos \left (d x + c\right )^{6} - 3 \, b \cos \left (d x + c\right )^{4} - 4 \, b \cos \left (d x + c\right )^{2} - 8 \, b\right )} \sin \left (d x + c\right )}{210 \, d} \]

[In]

integrate(cos(d*x+c)^5*sin(d*x+c)*(a+b*sin(d*x+c)),x, algorithm="fricas")

[Out]

-1/210*(35*a*cos(d*x + c)^6 + 2*(15*b*cos(d*x + c)^6 - 3*b*cos(d*x + c)^4 - 4*b*cos(d*x + c)^2 - 8*b)*sin(d*x
+ c))/d

Sympy [A] (verification not implemented)

Time = 0.44 (sec) , antiderivative size = 90, normalized size of antiderivative = 1.38 \[ \int \cos ^5(c+d x) \sin (c+d x) (a+b \sin (c+d x)) \, dx=\begin {cases} - \frac {a \cos ^{6}{\left (c + d x \right )}}{6 d} + \frac {8 b \sin ^{7}{\left (c + d x \right )}}{105 d} + \frac {4 b \sin ^{5}{\left (c + d x \right )} \cos ^{2}{\left (c + d x \right )}}{15 d} + \frac {b \sin ^{3}{\left (c + d x \right )} \cos ^{4}{\left (c + d x \right )}}{3 d} & \text {for}\: d \neq 0 \\x \left (a + b \sin {\left (c \right )}\right ) \sin {\left (c \right )} \cos ^{5}{\left (c \right )} & \text {otherwise} \end {cases} \]

[In]

integrate(cos(d*x+c)**5*sin(d*x+c)*(a+b*sin(d*x+c)),x)

[Out]

Piecewise((-a*cos(c + d*x)**6/(6*d) + 8*b*sin(c + d*x)**7/(105*d) + 4*b*sin(c + d*x)**5*cos(c + d*x)**2/(15*d)
 + b*sin(c + d*x)**3*cos(c + d*x)**4/(3*d), Ne(d, 0)), (x*(a + b*sin(c))*sin(c)*cos(c)**5, True))

Maxima [A] (verification not implemented)

none

Time = 0.19 (sec) , antiderivative size = 72, normalized size of antiderivative = 1.11 \[ \int \cos ^5(c+d x) \sin (c+d x) (a+b \sin (c+d x)) \, dx=\frac {30 \, b \sin \left (d x + c\right )^{7} + 35 \, a \sin \left (d x + c\right )^{6} - 84 \, b \sin \left (d x + c\right )^{5} - 105 \, a \sin \left (d x + c\right )^{4} + 70 \, b \sin \left (d x + c\right )^{3} + 105 \, a \sin \left (d x + c\right )^{2}}{210 \, d} \]

[In]

integrate(cos(d*x+c)^5*sin(d*x+c)*(a+b*sin(d*x+c)),x, algorithm="maxima")

[Out]

1/210*(30*b*sin(d*x + c)^7 + 35*a*sin(d*x + c)^6 - 84*b*sin(d*x + c)^5 - 105*a*sin(d*x + c)^4 + 70*b*sin(d*x +
 c)^3 + 105*a*sin(d*x + c)^2)/d

Giac [A] (verification not implemented)

none

Time = 0.35 (sec) , antiderivative size = 103, normalized size of antiderivative = 1.58 \[ \int \cos ^5(c+d x) \sin (c+d x) (a+b \sin (c+d x)) \, dx=-\frac {a \cos \left (6 \, d x + 6 \, c\right )}{192 \, d} - \frac {a \cos \left (4 \, d x + 4 \, c\right )}{32 \, d} - \frac {5 \, a \cos \left (2 \, d x + 2 \, c\right )}{64 \, d} - \frac {b \sin \left (7 \, d x + 7 \, c\right )}{448 \, d} - \frac {3 \, b \sin \left (5 \, d x + 5 \, c\right )}{320 \, d} - \frac {b \sin \left (3 \, d x + 3 \, c\right )}{192 \, d} + \frac {5 \, b \sin \left (d x + c\right )}{64 \, d} \]

[In]

integrate(cos(d*x+c)^5*sin(d*x+c)*(a+b*sin(d*x+c)),x, algorithm="giac")

[Out]

-1/192*a*cos(6*d*x + 6*c)/d - 1/32*a*cos(4*d*x + 4*c)/d - 5/64*a*cos(2*d*x + 2*c)/d - 1/448*b*sin(7*d*x + 7*c)
/d - 3/320*b*sin(5*d*x + 5*c)/d - 1/192*b*sin(3*d*x + 3*c)/d + 5/64*b*sin(d*x + c)/d

Mupad [B] (verification not implemented)

Time = 11.27 (sec) , antiderivative size = 71, normalized size of antiderivative = 1.09 \[ \int \cos ^5(c+d x) \sin (c+d x) (a+b \sin (c+d x)) \, dx=\frac {\frac {b\,{\sin \left (c+d\,x\right )}^7}{7}+\frac {a\,{\sin \left (c+d\,x\right )}^6}{6}-\frac {2\,b\,{\sin \left (c+d\,x\right )}^5}{5}-\frac {a\,{\sin \left (c+d\,x\right )}^4}{2}+\frac {b\,{\sin \left (c+d\,x\right )}^3}{3}+\frac {a\,{\sin \left (c+d\,x\right )}^2}{2}}{d} \]

[In]

int(cos(c + d*x)^5*sin(c + d*x)*(a + b*sin(c + d*x)),x)

[Out]

((a*sin(c + d*x)^2)/2 - (a*sin(c + d*x)^4)/2 + (a*sin(c + d*x)^6)/6 + (b*sin(c + d*x)^3)/3 - (2*b*sin(c + d*x)
^5)/5 + (b*sin(c + d*x)^7)/7)/d